﻿<root>
	<legendes />
	<infos>
		<creationDate>06/09/2012 15:16:37</creationDate>
		<modificationDate>27/10/2013 08:18:43</modificationDate>
		<revision>15</revision>
	</infos>
	<code>
		<template path="/String" name="length">
			<legendes />
			<params>
				<param>name</param>
				<param>value</param>
				<param>out</param>
			</params>
			<code>
				<beginprocess>$name</beginprocess>
				<usetemplate name="/CodeCommander/LoopWithWhile">
					<params>
						<param name="name">$nameLoop</param>
						<param name="counter">$nameIndex</param>
						<param name="init">1</param>
						<param name="limit">siVide</param>
					</params>
					<codings>
						<coding name="limit" indent="1">
							<code>
								<affectation indent="2">
									<variable>$namestr</variable>
									<expression>$value : $nameIndex</expression>
								</affectation>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameCondition</param>
										<param name="condition">$namestr?EmptyChar</param>
									</params>
									<codings>
										<coding name="true" indent="3">
											<code>
												<affectation indent="4">
													<variable>siVide</variable>
													<expression>false</expression>
												</affectation>
											</code>
										</coding>
										<coding name="false" indent="3">
											<code>
												<affectation indent="4">
													<variable>siVide</variable>
													<expression>true</expression>
												</affectation>
											</code>
										</coding>
									</codings>
								</usetemplate>
							</code>
						</coding>
						<coding name="increment" indent="1">
							<code>
								<affectation indent="2">
									<variable>$nameIndex</variable>
									<expression>$nameIndex + 1</expression>
								</affectation>
							</code>
						</coding>
						<coding name="body" indent="1">
							<code>
								<affectation indent="2">
									<variable>$out</variable>
									<expression>$out + 1</expression>
								</affectation>
							</code>
						</coding>
					</codings>
				</usetemplate>
				<endprocess>$name</endprocess>
				<affectation>
					<variable>$out</variable>
					<expression>0</expression>
				</affectation>
				<call>$name</call>
			</code>
		</template>
		<template path="/String" name="substring">
			<legendes />
			<params>
				<param>name</param>
				<param>value</param>
				<param>start</param>
				<param>length</param>
				<param>out</param>
			</params>
			<code>
				<beginprocess>$name</beginprocess>
				<usetemplate name="/CodeCommander/LoopWithWhile">
					<params>
						<param name="name">$nameLoop</param>
						<param name="counter">$nameIndex</param>
						<param name="init">0</param>
						<param name="limit">

							siVide
						</param>
					</params>
					<codings>
						<coding name="limit" indent="1">
							<code>
								<affectation indent="2">
									<variable>$namestr</variable>
									<expression>$value : $nameIndex</expression>
								</affectation>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameCondition</param>
										<param name="condition">$namestr?EmptyChar</param>
									</params>
									<codings>
										<coding name="true" indent="3">
											<code>
												<affectation indent="4">
													<variable>siVide</variable>
													<expression>false</expression>
												</affectation>
											</code>
										</coding>
										<coding name="false" indent="3">
											<code>
												<affectation indent="4">
													<variable>siVide</variable>
													<expression>true</expression>
												</affectation>
											</code>
										</coding>
									</codings>
								</usetemplate>
							</code>
						</coding>
						<coding name="increment" indent="1">
							<code>
								<affectation indent="2">
									<variable>$nameIndex</variable>
									<expression>$nameIndex + 1</expression>
								</affectation>
							</code>
						</coding>
						<coding name="body" indent="1">
							<code>
								<affectation indent="2">
									<variable>write</variable>
									<expression>false</expression>
								</affectation>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameEgalStart</param>
										<param name="condition">$nameIndex=$start</param>
									</params>
									<codings>
										<coding name="true" indent="3">
											<code>
												<affectation indent="4">
													<variable>write</variable>
													<expression>true</expression>
												</affectation>
											</code>
										</coding>
									</codings>
								</usetemplate>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameSupStart</param>
										<param name="condition">$nameIndex&amp;gt;$start</param>
									</params>
									<codings>
										<coding name="true" indent="3">
											<code>
												<affectation indent="4">
													<variable>write</variable>
													<expression>true</expression>
												</affectation>
											</code>
										</coding>
									</codings>
								</usetemplate>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameInfEnd</param>
										<param name="condition">$nameIndex&amp;lt;($start+$length)</param>
									</params>
									<codings>
										<coding name="false" indent="3">
											<code>
												<affectation indent="4">
													<variable>write</variable>
													<expression>false</expression>
												</affectation>
											</code>
										</coding>
									</codings>
								</usetemplate>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameWrite</param>
										<param name="condition">write</param>
									</params>
									<codings>
										<coding name="true" indent="3">
											<code>
												<affectation indent="4">
													<variable>$out</variable>
													<expression>$out . $namestr</expression>
												</affectation>
											</code>
										</coding>
									</codings>
								</usetemplate>
							</code>
						</coding>
					</codings>
				</usetemplate>
				<endprocess>$name</endprocess>
				<affectation>
					<variable>$out</variable>
					<expression>EmptyChar</expression>
				</affectation>
				<call>$name</call>
			</code>
		</template>
		<template path="/String" name="replace">
			<legendes />
			<params>
				<param>name</param>
				<param>value</param>
				<param>search</param>
				<param>replacement</param>
				<param>out</param>
			</params>
			<code>
				<beginprocess>$name</beginprocess>
				<usetemplate name="/CodeCommander/LoopWithWhile">
					<params>
						<param name="name">$nameLoop</param>
						<param name="counter">$nameIndex</param>
						<param name="init">0</param>
						<param name="limit">siVide</param>
					</params>
					<codings>
						<coding name="limit" indent="1">
							<code>
								<affectation indent="2">
									<variable>$namestr</variable>
									<expression>$value : $nameIndex</expression>
								</affectation>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameCondition</param>
										<param name="condition">$namestr?EmptyChar</param>
									</params>
									<codings>
										<coding name="true" indent="3">
											<code>
												<affectation indent="4">
													<variable>siVide</variable>
													<expression>false</expression>
												</affectation>
											</code>
										</coding>
										<coding name="false" indent="3">
											<code>
												<affectation indent="4">
													<variable>siVide</variable>
													<expression>true</expression>
												</affectation>
											</code>
										</coding>
									</codings>
								</usetemplate>
							</code>
						</coding>
						<coding name="increment" indent="1">
							<code>
								<affectation indent="2">
									<variable>$nameIndex</variable>
									<expression>$nameIndex + 1</expression>
								</affectation>
							</code>
						</coding>
						<coding name="body" indent="1">
							<code>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameFirst</param>
										<param name="condition">$namestr?($search:0)</param>
									</params>
									<codings>
										<coding name="true" indent="3">
											<code>
												<usetemplate name="/String/length" indent="4">
													<params>
														<param name="name">$nameLength</param>
														<param name="value">$search</param>
														<param name="out">$nameSearchLength</param>
													</params>
													<codings />
												</usetemplate>
												<usetemplate name="/String/substring" indent="4">
													<params>
														<param name="name">$nameSub</param>
														<param name="value">$value</param>
														<param name="start">$nameIndex</param>
														<param name="length">$nameSearchLength</param>
														<param name="out">sub</param>
													</params>
													<codings />
												</usetemplate>
												<usetemplate name="/CodeCommander/Condition" indent="4">
													<params>
														<param name="name">$nameSearch</param>
														<param name="condition">sub?$search</param>
													</params>
													<codings>
														<coding name="false" indent="5">
															<code>
																<affectation indent="6">
																	<variable>$out</variable>
																	<expression>$out . $namestr</expression>
																</affectation>
															</code>
														</coding>
														<coding name="true" indent="5">
															<code>
																<affectation indent="6">
																	<variable>$out</variable>
																	<expression>$out . $replacement</expression>
																</affectation>
																<affectation indent="6">
																	<variable>$nameIndex</variable>
																	<expression>$nameIndex + $nameSearchLength - 1</expression>
																</affectation>
															</code>
														</coding>
													</codings>
												</usetemplate>
											</code>
										</coding>
										<coding name="false" indent="3">
											<code>
												<affectation indent="4">
													<variable>$out</variable>
													<expression>$out . $namestr</expression>
												</affectation>
											</code>
										</coding>
									</codings>
								</usetemplate>
							</code>
						</coding>
					</codings>
				</usetemplate>
				<endprocess>$name</endprocess>
				<affectation>
					<variable>$out</variable>
					<expression>EmptyChar</expression>
				</affectation>
				<call>$name</call>
			</code>
		</template>
		<template path="/String" name="split">
			<legendes />
			<params>
				<param>name</param>
				<param>value</param>
				<param>search</param>
				<param>index</param>
				<param>out</param>
			</params>
			<code>
				<beginprocess>$name</beginprocess>
				<usetemplate name="/String/length">
					<params>
						<param name="name">$nameLength</param>
						<param name="value">$value</param>
						<param name="out">leng</param>
					</params>
					<codings />
				</usetemplate>
				<affectation>
					<variable>$nameBreak</variable>
					<expression>true</expression>
				</affectation>
				<affectation>
					<variable>$nameCounterSplit</variable>
					<expression>1</expression>
				</affectation>
				<usetemplate name="/CodeCommander/LoopConditionalWhile">
					<params>
						<param name="name">$nameW</param>
						<param name="counter">$nameCounter</param>
						<param name="init">1</param>
						<param name="limit">$nameBreak</param>
						<param name="condition">$nameCond</param>
					</params>
					<codings>
						<coding name="body" indent="1">
							<code>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameC4</param>
										<param name="condition">$nameCounterSplit&amp;lt;$index</param>
									</params>
									<codings>
										<coding name="true" indent="3">
											<code />
										</coding>
										<coding name="false" indent="3">
											<code>
												<affectation indent="4">
													<variable>$out</variable>
													<expression>$out . ($value : $nameCounter)</expression>
												</affectation>
											</code>
										</coding>
									</codings>
								</usetemplate>
							</code>
						</coding>
						<coding name="condition" indent="1">
							<code>
								<usetemplate name="/CodeCommander/Condition" indent="2">
									<params>
										<param name="name">$nameC3</param>
										<param name="condition">$nameCounter&amp;gt;leng</param>
									</params>
									<codings>
										<coding name="true" indent="3">
											<code>
												<affectation indent="4">
													<variable>$nameCond</variable>
													<expression>false</expression>
												</affectation>
												<affectation indent="4">
													<variable>$nameBreak</variable>
													<expression>false</expression>
												</affectation>
											</code>
										</coding>
										<coding name="false" indent="3">
											<code>
												<usetemplate name="/CodeCommander/Condition" indent="4">
													<params>
														<param name="name">$nameC1</param>
														<param name="condition">($value : $nameCounter)?$search</param>
													</params>
													<codings>
														<coding name="true" indent="5">
															<code>
																<affectation indent="6">
																	<variable>$nameCounterSplit</variable>
																	<expression>$nameCounterSplit + 1</expression>
																</affectation>
																<usetemplate name="/CodeCommander/Condition" indent="6">
																	<params>
																		<param name="name">$nameC2</param>
																		<param name="condition">$nameCounterSplit&amp;gt;$index</param>
																	</params>
																	<codings>
																		<coding name="true" indent="7">
																			<code>
																				<affectation indent="8">
																					<variable>$nameBreak</variable>
																					<expression>false</expression>
																				</affectation>
																			</code>
																		</coding>
																	</codings>
																</usetemplate>
																<affectation indent="6">
																	<variable>$nameCond</variable>
																	<expression>false</expression>
																</affectation>
															</code>
														</coding>
														<coding name="false" indent="5">
															<code>
																<affectation indent="6">
																	<variable>$nameCond</variable>
																	<expression>true</expression>
																</affectation>
															</code>
														</coding>
													</codings>
												</usetemplate>
											</code>
										</coding>
									</codings>
								</usetemplate>
							</code>
						</coding>
					</codings>
				</usetemplate>
				<endprocess>$name</endprocess>
				<affectation>
					<variable>$out</variable>
					<expression>EmptyChar</expression>
				</affectation>
				<call>$name</call>
			</code>
		</template>
	</code>
</root>